<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* The specificity of this selector is 1  */
        h1 {
            color: aqua;
        }

        /* The specificity of this selector is 10  */
        .cpurple {
            color: purple;
        }

        /* The specificity of this selector is 1 + 10 = 11  */
        h1.yellow {
            color: yellow;
        }

        /* This is an example of attribute selector. The specificity of this selector is 10 */
        [data-x=a] {
            color: maroon;
        }

        /* The specificity of this selector is 10  */
        .cred {
            color: red;
        }

        /* The specificity of this selector is 1 + 10 + 10 + 10 + 10 = 41  */
        a.harryclass.rohan-class[href]:hover {
            color: blueviolet;
        }
    </style>
</head>

<body>
    <div>
        <h1 class="yellow cred cpurple" data-x="a">CSS Specificity</h1>
    </div>
</body>

</html>